﻿<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="Chapter.aspx.cs" Inherits="com.dz.web.Chapter" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml" >
<head runat="server">
     <title></title>
    <meta http-equiv="Content-Type" content="text/html; charset=gb2312" />
    <meta name="keywords" id="mataKeywords" runat="server" content="" />
    <meta name="description" id="mataDescription" runat="server" content="" />
    <meta name="robots" content="all" /><meta name="googlebot" content="all" />
    <meta name="baiduspider" content="all" />
    
    <meta name="copyright" content="本页版权大种小说网所有。All Rights Reserved" />
      <LINK rel=STYLESHEET type=text/css href="/style/chapter.css" />
      <script src="/javascript/must.js" type="text/javascript"></script>
       <script src="/javascript/ajax.js" type="text/javascript"></script>
</head>
<body style='background:#e7f4fe'>
    <form id="form1" runat="server">
    <div>
    <DIV id=topBar>
<UL>
  <LI id=m_home><A href="/default.aspx">首页</A> </LI>
  <LI id=m_channel><A 
  href="#" onmousemove="ShowChannel()">频道</A><SPAN 
  id=channel_list style="display:none;">
  <a href="/category/XuanHuanQiHuan.aspx" >玄幻奇幻</a>
  <a href="/category/WuXiaXianXia.aspx">武侠仙侠</a>
 <a href="/category/DuShiYanQing.aspx">都市言情</a>
<a href="/category/LiShiJunShi.aspx">历史军事</a>
<a href="/category/YouXiJingJi.aspx">游戏竞技</a>
</SPAN> 
  </LI>
  
  <li id="login" >用户名：<input type="text" id="txtUserName"  />&nbsp;密码：<input type="password" id="txtPwd" />&nbsp;<input type="button" style="width:40px; height:18px;" class="login" value="登录" onclick="Login()" />&nbsp;&nbsp;<a href="/User/Register.aspx" target="_blank" class="green">注册</a></li>
   <li id="userInfo" style="display:none;"><label id="lblUserName"></label>&nbsp;&nbsp;<a href="/User/MyBookCase.aspx" target="_blank" class="green">我的书架</a>&nbsp;<a href="/User/MyCollect.aspx" target="_blank" class="green">我的推荐</a>&nbsp;&nbsp;<a href="#" onclick="LoginOut()">退出</a></li>
    <li style="float:right;"><a href="javascript:AddToFavorite();">加入收藏</a> </li>
      <li style="float:right;"><a href="javascript:setHomepage();">设为首页</a> </li>
    <li style="float:right;"><a href="/ShortCut.aspx" target="_blank">加入桌面</a> </li>
 </UL>
</DIV>

<DIV class=box>
<DIV id=location><A href="/default.aspx">首页</A>»  &nbsp;&nbsp;<a href="/ChapterList/<%=m_book_id %>.aspx"> 目录</a>»  &nbsp;&nbsp; <A href="javascript:goBook();"><%=m_book_name %></A> 
»  &nbsp;&nbsp;<SPAN id=selfChapterName><%=m_chapter_name%></SPAN></DIV>
</DIV>
<DIV id=seting class=box>
<DIV id=fontColor><STRONG>选择背景颜色：</STRONG> <SPAN onclick="SetB('#e8ebec',1)">1</SPAN> <SPAN  onclick="SetB('#e6ebef',1)">2</SPAN> <SPAN  onclick="SetB('#e7eeda',1)">3</SPAN> <SPAN  onclick="SetB('#eae6da',1)" >4</SPAN> <SPAN 
 onclick="SetB('#efe8ea',1)">5</SPAN> <SPAN  onclick="SetB('#f0ebe3',1)">6</SPAN> <SPAN  onclick="SetB('#e5e9e8',1)">7</SPAN> <SPAN 
v="#ececed">8</SPAN> </DIV>
<DIV id=fontSize><STRONG>选择字号：</STRONG> <SPAN onclick="SetF(24,1)">特大</SPAN> <SPAN 
v="18px">大</SPAN> <SPAN onclick="SetF(16,1)">中</SPAN> <SPAN onclick="SetF(14,1)">小</SPAN><SPAN onclick="javascript:SetF(14,1);SetB('#e7f4fe',1);">还原</SPAN><span style="margin-left:10px;" onclick="AddUserBook('bookcase')">【加入书架】</span><span onclick="AddUserBook('bookcommend')">【推荐次书】</span><span onclick="UpdateBook()">【请求更新】</span></DIV>
<P><A style="CURSOR: pointer" onclick="goPre()">上一篇</A>&nbsp;&nbsp;&nbsp;<A 
style="CURSOR: pointer" 
onclick="goNext()">下一篇</A>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;按左右键快速翻到上下章节</P></DIV>
<DIV class="wrap clear">
<DIV id=main class="leftc">
<DIV >
<TABLE class=thebc border=0 cellSpacing=0 cellPadding=0 
align=center>
  <TBODY>
  <TR>
    <TD id=tcn class=book_name01 colSpan=4 scope=col align=middle><%=m_chapter_name%></TD></TR>
    <tr>
    <td colspan="4" style="PADDING-BOTTOM: 40px; text-align:center;">
    
     <script type="text/javascript"><!--
google_ad_client = "ca-pub-0882577101519922";
/* 首页横幅 */
google_ad_slot = "4866106566";
google_ad_width = 728;
google_ad_height = 90;
//-->
</script>
<script type="text/javascript"
src="http://pagead2.googlesyndication.com/pagead/show_ads.js">
</script>
  

    </td>
    </tr>
  <TR class=thebc>
    <TD id=tcc  colSpan=4 
      scope=col>　
    <script src="<%=m_file_path %>"></script>
    <br />
    <span style=" COLOR: #900; FONT-SIZE: 28px; FONT-WEIGHT: bold; PADDING-TOP: 20px;">大种小说网(http://www.dazhongxiaoshuo.com)实时更新，完全免费</span>
    </TD></TR>
    <tr>
    <td class="bar">
    <script type="text/javascript"><!--
google_ad_client = "ca-pub-0882577101519922";
/* 章节阅读横幅头部 */
google_ad_slot = "7056249400";
google_ad_width = 468;
google_ad_height = 60;
//-->
</script>
<script type="text/javascript"
src="http://pagead2.googlesyndication.com/pagead/show_ads.js">
</script>
    </td>
    </tr>
    </TBODY></TABLE></DIV>

<asp:Label ID="lblChpaterContent" runat="server"></asp:Label>
<asp:Label ID="lblNickName" runat="server"></asp:Label>
<DIV id=bt3><SPAN onclick="goPre()">上一篇</SPAN> <SPAN 
onclick="goBook()">书页</SPAN>  <SPAN onclick="javascript:window.location.href='/ChapterList/<%=m_book_id %>.aspx';">目录</SPAN> <SPAN onclick="goNext()">下一篇</SPAN> </DIV>



</DIV>
<DIV class=box_r>

</DIV>
 <script>
   var bookId="<%=m_book_id %>";
   //字体大小$背景颜色
var c_config="read_config";
//设置cookie
function SetCookie(name, value)
{
    var Days = 360; //此 cookie 将被保存 30 天
    var exp  = new Date();    
    exp.setTime(exp.getTime() + Days*24*60*60*1000);
    document.cookie = name + "="+ escape (value) + ";expires=" + exp.toGMTString();

}


//获取cookie
function GetCookie(cookieName) 
{
     var cookieString = document.cookie;
 var start = cookieString.indexOf(cookieName + '=');
 if (start == -1)
     return null;
 start += cookieName.length + 1;
 var end = cookieString.indexOf(';', start);
 if (end == -1) return decodeURIComponent(cookieString.substring(start));
 return decodeURIComponent(cookieString.substring(start, end));
}
//获取阅读配置 0 字体大小 1背景颜色 
function GetC(type)
{
var c="#e7f4fe";
var r_c=GetCookie(c_config);
if(r_c!="undefined" && r_c!=null && r_c!="")
{
var r=r_c.split('$');
if(r.length>type)
{
return r[type];
}
else 
return "";
} 
return "";
}

//设置字体
function SetF(size,click)
{

var b=GetC(0);
var c=GetC(1);
if(size!=0 && click==1)
{
    b=size;
}
if(b=="" || b=="undefined")
{
    b=size;
}
document.getElementById("tcc").style.fontSize=b;
SetCookie(c_config,b+"$"+c);
}
//设置背景色
function SetB(color,click)
{
var b=GetC[0];
var c=GetC(1);
if(color!="" && click==1)
{
    c=color;
}
if(c=="")
{
    c=color;
}
document.body.style.background=c;
SetCookie(c_config,b+"$"+c);
}

function pageEvent(b)
{

b=b||window.event;var a=b.which||b.keyCode;
if(a==37)
{
  goPre();
}
if(a==39)
{
    goNext();
 }
}
document['onkeydown'] = pageEvent; 
//上一章
function goPre()
{
   if(typeof(preChapterId)!="undefined" && preChapterId!=null)
   {
       if(parseInt(preChapterId)<=0)
       {
          alert("已经是第一章节了!");
          return false;
        
       }
         window.location.href="/chapter/"+bookId+","+preChapterId+".aspx";
   }
}
//下一章
function goNext()
{
    if(typeof(nextChapterId)!="undefined" && nextChapterId!=null)
    {
       if(parseInt(nextChapterId)<=0)
       {
          alert("已经是最后一个章节了!");
          return false;
        
       }
       window.location.href="/chapter/"+bookId+","+nextChapterId+".aspx";
    }
}
function goBook()
{
 window.location.href="/"+bookId+".aspx";
}
function ShowChannel()
{
    document.getElementById("channel_list").style.display="";
}
function HidChannel()
{
 document.getElementById("channel_list").style.display="none";

}
//添加到收藏夹   
function AddToFavorite()   
{   
    if (document.all){   
       window.external.addFavorite(document.URL,document.title);   
    }else if (window.sidebar){   
       window.sidebar.addPanel(document.title, document.URL, "");   
    }   
}   
  
//设为首页   
function setHomepage(){   
    if (document.all){   
    document.body.style.behavior='url(#default#homepage)';   
    document.body.setHomePage(document.URL);   
  }else if (window.sidebar){   
        if(window.netscape){   
       try{    
          netscape.security.PrivilegeManager.enablePrivilege("UniversalXPConnect");    
       }catch (e){    
                    alert( "该操作被浏览器拒绝，如果想启用该功能，请在地址栏内输入 about:config,然后将项 signed.applets.codebase_principal_support 值该为true" );    
       }   
        }    
    var prefs = Components.classes['@mozilla.org/preferences-service;1'].getService(Components. interfaces.nsIPrefBranch);   
    prefs.setCharPref('browser.startup.homepage',document.URL);   
    }   
} 
function LoginOut()
{
    MyAjax.ExcuteScript("loginout","out",ShowLoginOutBack);
}
function ShowLoginOutBack(result)
{
    if(result.value.indexOf("成功")>-1)
    {
        $("userInfo").style.display="none";
        $("login").style.display="";
        $("lblUserName").innerHTML="";
    }
}


function Login()
{
    var u=$("txtUserName").value;
    var p=$("txtPwd").value;
    if(u==""|| p=="")
    {
        alert("请输入用户名和密码!");
        return false;
    }
    MyAjax.ExcuteScript("login",u+"$"+p,ShowLoginBack);
}
function ShowLoginBack(r)
{
    var ret=r.value;
    var arr=ret.split("$");
    if(arr!=null && arr.length>0)
    {
        if(arr[0].indexOf("成功")>-1)
        {
            $("lblUserName").innerHTML=arr[1];
            $("userInfo").style.display="";
            $("login").style.display="none";
        }
        else
        {
            alert(arr[1]);
        }
    }
}
function AddUserBook(bookType)
{
    var isLogin=CheckUserLogin();

    if(isLogin==false)
    {
        alert("您还没有登录，请先登录!");
        $("txtUserName").focus();
        return false;
    }
    MyAjax.ExcuteScript(bookType,bookId,ShowAddUserBookBack);
}
function ShowAddUserBookBack(result)
{
    alert(result.value);
}
function UpdateBook()
{
    var bookId="<%=m_book_id %>";
     MyAjax.ExcuteScript("updatebook",bookId,ShowUpdateBack);
}
function ShowUpdateBack(result)
{
    if(result.value.indexOf("成功")>-1)
    {
        alert("更新请求已经提交,我们会尽快更新本书章节,敬请关注!");
        
    }
    else
    {
        alert(result.value);
    }
}
   </script>
<DIV id=tcopyright class=tcopyright>
<div>
<p><%=com.dz.common.AppConfig.SiteName%>所收录免费小说作品、书库评论及<%=com.dz.common.AppConfig.SiteName%>所做之广告均属用户个人行为，与<%=com.dz.common.AppConfig.SiteName%>无关</p><p>本站小说完全收录于互联网,共享给网友免费阅读,如有侵害你权力的地方，请与管理员里联系</p>
</div>
<DIV><A href="#/">关于<%=com.dz.common.AppConfig.SiteName%> </A>| <A 
href="#">版权说明</A> | <A 
href="#">服务条款</A>  </DIV>
<DIV class=en>Copyright &copy; 2010 <a href="<%=com.dz.common.AppConfig.SiteUrl%>" target="_blank"><%=com.dz.common.AppConfig.SiteName%> </a> </DIV>
<DIV><%=com.dz.common.AppConfig.SiteName%>  <A href="<%=com.dz.common.AppConfig.SiteUrl%>" 
target=_blank>版权所有</A> </DIV></DIV>
</DIV>

<label id="lblStat"></label>

    </div>
    </form>
    <script>
if(typeof(nickName)!="undefined" && nickName !=null && nickName !="")
{

$("lblUserName").innerHTML=nickName;
$("userInfo").style.display="";
$("login").style.display="none";
}
     document.body.onclick=HidChannel;
     document.getElementById("channel_list").onclick=HidChannel;
     SetF(16,0);
     SetB("#e7f4fe",0);
    </script>
 <div style="display:none;">
   <%if (com.dz.common.AppConfig.SiteName == "大种小说")
  { %>
<script language="javascript" type="text/javascript" src="http://js.users.51.la/4550804.js"></script>

<%}
  else
  { %>
<script language="javascript" type="text/javascript" src="http://js.users.51.la/4550848.js"></script>

 <%} %>
 </div>
</body>
 
</html>
